\documentclass[10pt,a4paper]{article}
\usepackage[T1]{fontenc}
\usepackage[a4paper]{geometry}
\usepackage{xcolor}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage{tabularx}
\usepackage{multirow}
\usepackage{subfigure}
\usepackage{verbatim}
\usepackage{fancyhdr}
\usepackage{listings}
\usepackage{../common/espacs}

%\input{../common/commands.tex}


\newcommand*{\vect}[1]{\boldsymbol{#1}}
\newcommand*{\mat}[1]{\boldsymbol{#1}}

%\author{}
\title{Exercise Session 7}
\date{November 23, 2012}

\pagestyle{fancy}
\headheight 35pt

\begin{document}
\lstset{language=[ISO]C++}
\maketitle

\section*{Random walk and the Fourier equation}

As throughfully explained in S. Salsa, \emph{Equazioni a derivate parziali},
Chp.~2, there is a direct connection between the Fourier equation
\begin{equation}
\label{eqn:fourier}
u_t - D \, u_{xx} = f
\end{equation}
with suitable boundary and initial conditions, and the unidimensional random
process known as Brownian motion. In particular, the fundamental solution to
\eqref{eqn:fourier} is the Gaussian distribution
\[
G(x,t) = \frac{1}{\sqrt{ 4 \pi D t}} \exp{-\frac{x^2}{4 D t}}
\]
%
\begin{figure}
\centering
\includegraphics[width=.6\textwidth]{fig/randomlap20}
\caption{Discrete distribution and continuous distribution for set of particles
         in 1D Brownian motion at $t = 20$.}
\label{fig:distr}
\end{figure}
%
This distribution can be seen as the limiting case, with the number of particles
that goes to infinity, while the lenght of the step and the time go to zero, of
the discrete distribution of a randomly walking set of particles, under the
hypothesis that the probability of moving to left or to the right are exactly
$\frac{1}{2}$ each. The distribution, along with the fundamental solution is
plotted in Fig. \ref{fig:distr}.


\input{ex}

\input{ex_sol}

\end{document}
